<?php

/**

 * @authors alex (20779512@qq.com)

 * @date    2014-03-24 17:25:39

 * @version 1.0

 */

namespace Admin\Controller;

class SiteController extends AdminController {

    

    #网站设置

    public function info(){

    	$this->display();

    }



    #附件设置

    public function upfile(){

    	$this->display();

    }



    #保存配置

    public function insert(){



    	$file=I('post.files');

		unset($_POST['files']);

		

		if($this->update_config($_POST,CONF_PATH.$file)){

			$state = 'SUCCESS';

          	$message = 'Successful operation';

		  	//$url = U('Site/info');

		}else{

			$state = 'Operation failed
';

		}

		echo $this->echo_json_str($state,$message,$url);

    }



}